package cn.doitedu.dmp.crawler;

import org.jsoup.Jsoup;
import org.jsoup.nodes.Document;
import org.openqa.selenium.chrome.ChromeDriver;
import org.openqa.selenium.chrome.ChromeOptions;

import java.io.IOException;

public class JdProductInfoExtract {


    public static void main(String[] args) throws IOException {
        System.setProperty("webdriver.chrome.driver","C:\\Users\\83544\\AppData\\Local\\Google\\Chrome\\Application\\chromedriver.exe");

        ChromeOptions options = new ChromeOptions();
        options.addArguments("headless");

        ChromeDriver driver = new ChromeDriver(options);
        driver.get("https://list.jd.com/list.html?cat=670,671,672");
        String pageSource = driver.getPageSource();
        Document doc = Jsoup.parse(pageSource);
        System.out.println(doc);
    }

}
